<html>
    <head>
        <title>原材料类型列表</title>
        <link href="{$Think.const.ADMIN_CSS_URL}bootstrap.css" rel="stylesheet" />
        <link href="{$Think.const.ADMIN_CSS_URL}lz-style.css" rel="stylesheet" />
        <script src="{$Think.const.ADMIN_JS_URL}jquery.js"></script>
        <script src="{$Think.const.ADMIN_JS_URL}bootstrap.js"></script>
        <script src="{$Think.const.ADMIN_JS_URL}dataTables/jquery.dataTables.js"></script>
        <script src="{$Think.const.ADMIN_JS_URL}dataTables/dataTables.bootstrap.js"></script>
        <script src="{$Think.const.ADMIN_JS_URL}DatePicker/WdatePicker.js"></script>
        <script>
            $(document).ready(function () {
                $('#dataTables').dataTable({
                    paging: true,
                    searching: false,
                    showrownumber: true
                });
            });
        </script>
    </head>
    <body>
        <div class="container">
            <div class="row div_head" >
                <div class=" col-xs-6 col-sm-6 text-primary">
                    {$loction}
                </div>
                <div class=" col-xs-6 col-sm-3"></div>
                <div class=" col-xs-6 col-sm-3">
                    <a style="text-decoration: none;" href="__CONTROLLER__/add">【添加】</a>
                </div>
            </div>
            <hr />
            <div class="row div_form" >
                <form action="__SELF__" method="post">
<div class="text-right col-xs-6 col-sm-3 " ><label for="MaterialTypeName" class="control-label">{$Think.const.LB_MATERIALTYPENAME}:</label></div>
                    <div class="col-xs-6 col-sm-3 div_text" >
                        <input type="text" id="MaterialTypeName" name="MaterialTypeName" class="form-control" placeholder="{$Think.const.LB_MATERIALTYPENAME}"  value="" maxlength="100"/>
                    </div>



                    <div class="col-xs-6 col-sm-3">
                        <input type="submit" id="search"  class="btn btn-default" value="查询">
                    </div>

                </form>
                <div id="error" class="row text-danger"></div>
                <div id="success" class="row text-success"></div>
            </div>
            <hr />
            <div class="row div_content" >
                <div class="col-md-12">
                    <div class="table-responsive">
                        <table class="table table-striped table-bordered table-hover table-condensed" id="dataTables" border="1">
                            <thead>
                                <tr>
                                    <th class="div_tab_head">序号</th>

                    <th class="div_tab_head">{$Think.const.LB_MATERIALTYPENAME}</th>

                    <th class="div_tab_head">{$Think.const.LB_MATERIALTYPEDESC}</th>

                                    <th class="div_tab_head">操作</th>
                                </tr>
                            </thead>
                            <tbody>
                            <foreach name="lst" item="row" >
                                <tr>
                                    <td class="div_tab_cell">{$key+1}</td>
                    <td class="div_tab_cell div_tab_cell_text">{$row.materialtypename|stripcslashes}</td>
                    <td class="div_tab_cell div_tab_cell_text">{$row.materialtypedesc|stripcslashes}</td>

                                    <td align="center" class="div_tab_cell"><div class="btn-group">
                                            <a id="edit" type="button" class="btn btn-default" href="__CONTROLLER__/edit/MaterialTypeID/{$row.materialtypeid}"><span class="glyphicon glyphicon-pencil"></span></a>
                                            <a id="delete" type="button" class="btn btn-default"href="__CONTROLLER__/del/MaterialTypeID/{$row.materialtypeid}" onClick="if (confirm('确定要删除吗？'))
                                                        return true;
                                                    else
                                                        return false;"><span class="glyphicon glyphicon-remove"></span></a>
                                        </div></td>
                                </tr>
                            </foreach>
                            </tbody>
                        </table>
                    </div>
                </div>
            </div>
        </div>

    </body>
</html>
